package com.fxm.vo;

import java.io.Serializable;

public class PageVO implements Serializable{
	private int pageIndex = 1;
	private int pageSize = 10;
	private int count;
	
	public int getPageCount(){
		if(count%pageSize==0){
			return count/pageSize;
		}else{
			return count/pageSize + 1;
		}
	}
	public int getBegin(){
		return (pageIndex-1)*pageSize + 1;
	}
	public int getEnd(){
		return pageIndex*pageSize;
	}
	
	public int getPageIndex() {
		return pageIndex;
	}
	public void setPageIndex(int pageIndex) {
		this.pageIndex = pageIndex;
	}
	public int getPageSize() {
		return pageSize;
	}
	public void setPageSize(int pageSize) {
		this.pageSize = pageSize;
	}
	public int getCount() {
		return count;
	}
	public void setCount(int count) {
		this.count = count;
	}
	public PageVO() {
		super();
	}
	public PageVO(int pageIndex, int pageSize, int count) {
		super();
		this.pageIndex = pageIndex;
		this.pageSize = pageSize;
		this.count = count;
	}
}
